package com.suzhe.ymall.promotion.service;

import com.suzhe.ymall.common.pojo.ApiResEntity;
import com.suzhe.ymall.promotion.param.LockCouponParam;
import com.suzhe.ymall.promotion.pojo.UserCoupon;
import com.baomidou.mybatisplus.extension.service.IService;

/**
 * <p>
 * 用户优惠券表 服务类
 * </p>
 *
 * @author suzhe
 * @since 2019-08-18
 */
public interface IUserCouponService extends IService<UserCoupon> {

    /**
     * 锁券
     * @param lockCouponParam
     * @return
     */
    ApiResEntity lockUserCoupon(LockCouponParam lockCouponParam);

    /**
     * 回滚
     * @param orderNo
     */
    void rollbackOrder(String messageId,String orderNo);

    /**
     * 订单成功
     * @param orderNo
     */
    void orderSuccess(String messageId,String orderNo);
}
